package org.pay.core.entity;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

public class MchInfo implements Serializable {
    /**
     * 商户ID
     *
     * @mbggenerated
     */
    private Long mchId;

    /**
     * 名称
     *
     * @mbggenerated
     */
    private String name;

    /**
     * 类型:1-平台账户,2-私有账户
     *
     * @mbggenerated
     */
    private Byte kind;

    /**
     * 手机号
     *
     * @mbggenerated
     */
    private Long mobile;

    /**
     * 邮箱
     *
     * @mbggenerated
     */
    private String email;

    /**
     * 密码
     *
     * @mbggenerated
     */
    private String cipher;

    /**
     * 支付密码,默认abc123456
     *
     * @mbggenerated
     */
    private String payPassword;

    /**
     * 角色
     *
     * @mbggenerated
     */
    private String role;

    /**
     * 商户费率,百分比
     *
     * @mbggenerated
     */
    private BigDecimal mchRate;

    /**
     * 私钥
     *
     * @mbggenerated
     */
    private String privateKey;

    /**
     * 风险预存期
     *
     * @mbggenerated
     */
    private Integer riskDay;

    /**
     * 是否自动结算,0-不自动结算,1-自动结算
     *
     * @mbggenerated
     */
    private Byte isAutoSett;

    /**
     * 结算方式,1-T+1到账,2-T+0到账,3-D+0到账
     *
     * @mbggenerated
     */
    private Byte settType;

    /**
     * 商户状态,-1-待审核,0-停止使用,1-使用中
     *
     * @mbggenerated
     */
    private Byte state;

    /**
     * 备注
     *
     * @mbggenerated
     */
    private String remark;

    /**
     * 最后一次重置密码时间
     *
     * @mbggenerated
     */
    private Date lastPasswordResetTime;

    /**
     * 创建时间
     *
     * @mbggenerated
     */
    private Date createTime;

    /**
     * 更新时间
     *
     * @mbggenerated
     */
    private Date updateTime;

    private static final long serialVersionUID = 1L;

    public Long getMchId() {
        return mchId;
    }

    public void setMchId(Long mchId) {
        this.mchId = mchId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Byte getKind() {
        return kind;
    }

    public void setKind(Byte kind) {
        this.kind = kind;
    }

    public Long getMobile() {
        return mobile;
    }

    public void setMobile(Long mobile) {
        this.mobile = mobile;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getCipher() {
        return cipher;
    }

    public void setCipher(String cipher) {
        this.cipher = cipher;
    }

    public String getPayPassword() {
        return payPassword;
    }

    public void setPayPassword(String payPassword) {
        this.payPassword = payPassword;
    }

    public String getRole() {
        return role;
    }

    public void setRole(String role) {
        this.role = role;
    }

    public BigDecimal getMchRate() {
        return mchRate;
    }

    public void setMchRate(BigDecimal mchRate) {
        this.mchRate = mchRate;
    }

    public String getPrivateKey() {
        return privateKey;
    }

    public void setPrivateKey(String privateKey) {
        this.privateKey = privateKey;
    }

    public Integer getRiskDay() {
        return riskDay;
    }

    public void setRiskDay(Integer riskDay) {
        this.riskDay = riskDay;
    }

    public Byte getIsAutoSett() {
        return isAutoSett;
    }

    public void setIsAutoSett(Byte isAutoSett) {
        this.isAutoSett = isAutoSett;
    }

    public Byte getSettType() {
        return settType;
    }

    public void setSettType(Byte settType) {
        this.settType = settType;
    }

    public Byte getState() {
        return state;
    }

    public void setState(Byte state) {
        this.state = state;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public Date getLastPasswordResetTime() {
        return lastPasswordResetTime;
    }

    public void setLastPasswordResetTime(Date lastPasswordResetTime) {
        this.lastPasswordResetTime = lastPasswordResetTime;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", mchId=").append(mchId);
        sb.append(", name=").append(name);
        sb.append(", kind=").append(kind);
        sb.append(", mobile=").append(mobile);
        sb.append(", email=").append(email);
        sb.append(", cipher=").append(cipher);
        sb.append(", payPassword=").append(payPassword);
        sb.append(", role=").append(role);
        sb.append(", mchRate=").append(mchRate);
        sb.append(", privateKey=").append(privateKey);
        sb.append(", riskDay=").append(riskDay);
        sb.append(", isAutoSett=").append(isAutoSett);
        sb.append(", settType=").append(settType);
        sb.append(", state=").append(state);
        sb.append(", remark=").append(remark);
        sb.append(", lastPasswordResetTime=").append(lastPasswordResetTime);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateTime=").append(updateTime);
        sb.append("]");
        return sb.toString();
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        MchInfo other = (MchInfo) that;
        return (this.getMchId() == null ? other.getMchId() == null : this.getMchId().equals(other.getMchId()))
            && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
            && (this.getKind() == null ? other.getKind() == null : this.getKind().equals(other.getKind()))
            && (this.getMobile() == null ? other.getMobile() == null : this.getMobile().equals(other.getMobile()))
            && (this.getEmail() == null ? other.getEmail() == null : this.getEmail().equals(other.getEmail()))
            && (this.getCipher() == null ? other.getCipher() == null : this.getCipher().equals(other.getCipher()))
            && (this.getPayPassword() == null ? other.getPayPassword() == null : this.getPayPassword().equals(other.getPayPassword()))
            && (this.getRole() == null ? other.getRole() == null : this.getRole().equals(other.getRole()))
            && (this.getMchRate() == null ? other.getMchRate() == null : this.getMchRate().equals(other.getMchRate()))
            && (this.getPrivateKey() == null ? other.getPrivateKey() == null : this.getPrivateKey().equals(other.getPrivateKey()))
            && (this.getRiskDay() == null ? other.getRiskDay() == null : this.getRiskDay().equals(other.getRiskDay()))
            && (this.getIsAutoSett() == null ? other.getIsAutoSett() == null : this.getIsAutoSett().equals(other.getIsAutoSett()))
            && (this.getSettType() == null ? other.getSettType() == null : this.getSettType().equals(other.getSettType()))
            && (this.getState() == null ? other.getState() == null : this.getState().equals(other.getState()))
            && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
            && (this.getLastPasswordResetTime() == null ? other.getLastPasswordResetTime() == null : this.getLastPasswordResetTime().equals(other.getLastPasswordResetTime()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getMchId() == null) ? 0 : getMchId().hashCode());
        result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
        result = prime * result + ((getKind() == null) ? 0 : getKind().hashCode());
        result = prime * result + ((getMobile() == null) ? 0 : getMobile().hashCode());
        result = prime * result + ((getEmail() == null) ? 0 : getEmail().hashCode());
        result = prime * result + ((getCipher() == null) ? 0 : getCipher().hashCode());
        result = prime * result + ((getPayPassword() == null) ? 0 : getPayPassword().hashCode());
        result = prime * result + ((getRole() == null) ? 0 : getRole().hashCode());
        result = prime * result + ((getMchRate() == null) ? 0 : getMchRate().hashCode());
        result = prime * result + ((getPrivateKey() == null) ? 0 : getPrivateKey().hashCode());
        result = prime * result + ((getRiskDay() == null) ? 0 : getRiskDay().hashCode());
        result = prime * result + ((getIsAutoSett() == null) ? 0 : getIsAutoSett().hashCode());
        result = prime * result + ((getSettType() == null) ? 0 : getSettType().hashCode());
        result = prime * result + ((getState() == null) ? 0 : getState().hashCode());
        result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
        result = prime * result + ((getLastPasswordResetTime() == null) ? 0 : getLastPasswordResetTime().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        return result;
    }
}